package com.jl.dao;

import com.mchange.v2.c3p0.ComboPooledDataSource;
import org.apache.commons.dbutils.QueryRunner;

import javax.sql.DataSource;
import java.sql.SQLException;

public class SignDao {
    public int saveCustormer(String username,String password,String email) throws SQLException {
        DataSource dataSource = new ComboPooledDataSource();
        QueryRunner queryRunner = new QueryRunner(dataSource);
        Object[] custorm = {null,username,password,email};
        int update = queryRunner.update("insert into custorm values(null,?,?,?)",custorm);
        return update;
    }
}
